Skip to main content

Sort Table

AutomatR.Excel.Activities.SortTable

The "Sort Table" activity in AutomatR is part of the Excel activities package, allowing users to sort data within a table in a Microsoft Excel spreadsheet. This activity provides the flexibility to specify the table, the column to sort, and the sorting order (ascending or descending).

NOTE: This activity can only be used in Excel Root activity.

Properties

NameDescription
Input
Column IndexEnter the index for the column to apply the sort on. Integer variables containing the column index.
Table NameEnter the name of the table to be sorted. String variables containing the desired table name.
Misc
Display NameThe display name of the activity. A display name is automatically generated when you indicate a target.
Sort TypeSelect the type of sort to be applied, either Ascending or Descending. Enumeration variable (SortOrder) containing the desired sort order.
Ascending - order from smallest to biggest (numbers) or from A to Z (alphabetic characters).
Descending - order from biggest to smallest (numbers) or from Z to A (alphabetic characters).
Optional
DelayEnter the wait time in seconds (Example: 5 seconds i.e., 5) to start the activity. Integer variables containing the delay duration.

How to use:

  1. Drag and drop the "Sort Table" activity onto the workflow.
  2. Configure the properties by specifying the table name, column index, and sort type (Ascending or Descending).
  3. Optionally, configure the delay.
  4. Execute the workflow to sort the specified table within the Excel spreadsheet.

Important:

  • Ensure that the Excel workbook and sheet are open and accessible.
  • The specified table name should be valid; otherwise, an "Invalid Table name" error will occur.
  • The column index should be the index of the column to sort, and the sort type should be selected based on the desired sorting order.